<!DOCTYPE html>
<html>
<head>
  <meta charset="UTF-8">
  <title>Document</title>
</head>
<body>
  手机号码：<input type="number">
  <button>发送</button>
  <script>
    var btn = document.querySelector("button")
    var time = 5
    btn.onclick = function()
    {
        btn.disabled = true;
        var id = setInterval(function(){
            time--
            btn.innerHTML="还剩下" + time + "秒"
            if(time==0)
            {
                clearInterval(id)
                btn.disabled = false
                btn.innerHTML="发送"
            }
        },1000)
    }
  </script>
</body>
</html>